Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Patient Details Endpoints #174

Merged
merged 15 commits into from
Feb 4, 2025
Merged

Patient Details Endpoints #174

merged 15 commits into from
Feb 4, 2025

Conversation

cbrinson-rise8
Copy link
Contributor

@cbrinson-rise8 cbrinson-rise8 commented Jan 21, 2025

Description

Add two new API endpoints that allow users to directly add/update patient record details in the MPI.

Related Issues

closes #159

Additional Notes

POST /patient -d '{"record": "...", "person": "person_reference_id"}'
Add the above endpoint to allow users to directly add a patient record to the MPI, skipping the record linkage algorithm.

PATCH /patient/<patient-reference-id> -d '{"record": "...", "person": "person_reference_id"}'
Add the above endpoint to allow users to update an existing patient record in the MPI.
NOTE: For this operation, the record and person attributes are optional. If not specified, the existing value will stay unchanged. However, at least 1 must be specified.

<--------------------- REMOVE THE LINES BELOW BEFORE MERGING --------------------->

Checklist

Please review and complete the following checklist before submitting your pull request:

  • I have ensured that the pull request is of a manageable size, allowing it to be reviewed within a single session.
  • I have reviewed my changes to ensure they are clear, concise, and well-documented.
  • I have updated the documentation, if applicable.
  • I have added or updated test cases to cover my changes, if applicable.
  • I have minimized the number of reviewers to include only those essential for the review.

Checklist for Reviewers

Please review and complete the following checklist during the review process:

  • The code follows best practices and conventions.
  • The changes implement the desired functionality or fix the reported issue.
  • The tests cover the new changes and pass successfully.
  • Any potential edge cases or error scenarios have been considered.

@cbrinson-rise8 cbrinson-rise8 self-assigned this Jan 21, 2025
@cbrinson-rise8 cbrinson-rise8 added the feature New feature or request label Jan 21, 2025
Copy link

codecov bot commented Jan 21, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 97.59%. Comparing base (e837f63) to head (dc997c4).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #174      +/-   ##
==========================================
+ Coverage   97.51%   97.59%   +0.08%     
==========================================
  Files          31       31              
  Lines        1486     1541      +55     
==========================================
+ Hits         1449     1504      +55     
  Misses         37       37              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@ericbuckley ericbuckley marked this pull request as ready for review January 24, 2025 21:26
Copy link
Collaborator

@m-goggins m-goggins left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ericbuckley Looks pretty good to me, though I think some of the docstrings and error messages could potentially be improved to make the new functionality clearer to users. It seems like the error messages in the codebase are fairly minimal so I'm not sure if that was a decision the team previously made. I tend to err on the side of more descriptive errors.

ericbuckley and others added 4 commits February 3, 2025 14:27
Co-authored-by: Marcelle <53578688+m-goggins@users.noreply.github.com>
Co-authored-by: Marcelle <53578688+m-goggins@users.noreply.github.com>
@ericbuckley ericbuckley merged commit 5b5fe41 into main Feb 4, 2025
15 checks passed
@ericbuckley ericbuckley deleted the feat/patient-details-endpoint branch February 4, 2025 17:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

API endpoints to add patient details directly to MPI [MPIAPI]
3 participants